<template>
  <div class="BlockBox_v" :style="{width:width,height:height}">
    <div class="header">
      <slot name="title"></slot>
    </div>
    <div class="content">
      <slot name="content"></slot>
    </div>
  </div>
</template>

<script setup>

const props = defineProps({
  width: {
    type: String,
    default: function() {
      return "100%";
    }
  },
  height: {
    type: String,
    default: function() {
      return "100%";
    }
  },
  title: {
    type: String,
    default: function() {
      return "";
    }
  }
})

</script>

<style scoped lang="less">
.BlockBox_v {
  width: 100%;
  min-width: 450px;
  height: 100%;
  border: 1px solid #e5e5e5;
  border-radius: 4px;

  .header {
    width: 100%;
    height: 50px;
    line-height: 50px;
    background-color: #f1f1f1;
    font-weight: bold;
    box-sizing: border-box;
    padding: 0 10px;
  }

  .content {
    width: 100%;
    height: calc(100% - 50px);
    padding: 10px;
  }
}
</style>